/*
 * RegexpFilter.h
 * Author: Michal Kolodziejski
 */

#ifndef REGEXPFILTER_H_
#define REGEXPFILTER_H_

#include <string>
#include <list>
#include <fstream>
#include <boost/regex.hpp>
#include "AbstractFilter.h"

/**
 * Filter that deletes all occurrences of strings matching regular expressions
 * defined in configuration file.
 */
class RegexpFilter: public AbstractFilter {
public:
    RegexpFilter();
    virtual ~RegexpFilter();


    virtual std::string getName(){
        return NAME;
    }

    virtual bool process(std::string &content);

    virtual bool processConfig(std::string path);

private:
    const std::string NAME;
    typedef std::list<boost::regex> FiltersList;
    FiltersList filters;
};

#endif /* REGEXPFILTER_H_ */
